<template>
    <div>
        <td><input type="text" v-model="state.Name"></td>
        <td><input type="button" value="查询" @click=""></td>
<table>
    <tr>
        <td>编号</td>
        <td>名称</td>
        <td>市场价</td>
        <td>押金</td>
        <td>图片</td>
        <td>状态</td>
    </tr>
    <tr v-for="item in list">
        <td>{{ item.id }}</td>
        <td>{{ item.name }}</td>
        <td>{{ item.price }}</td>
        <td>{{ item.deposit }}</td>
        <td>
            <img :src="'https://localhost:7021'" + item.img alt="" width="50px" height="50px">
        </td>
        <td>{{ item.state=1?"通过":"未通过" }}</td>
    </tr>
</table>
    </div>
</template>

<script setup lang="ts">
import { reactive,toRefs,onMounted } from 'vue';
import { useRouter,useRoute } from 'vue-router';
import axios from 'axios'
const router = useRouter()
const route = useRoute()

const data:any = reactive({
    state:{
        Name:'',
        index:'',
        size:''
    },
    
   list:[],
   count:0,
   pcount:0,

});

const {state,list,count,pcount} = toRefs(data)

onMounted(()=>{
  funshow()
})
const funshow = ()=>{
    axios({
   url:'https://localhost:7021/api/Member/ShowMember',
    method:'get',
    params:state.value
    }).then((res)=>{
        data.list = res.data.list.data
        data.count = res.data.count.data
        data.pcount = res.data.pcount.data
    })
}



</script>

<style scoped>

</style>